package com.chengh.nami.common.domain.pojo;

import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableName;
import com.chengh.nami.common.domain.BaseEntity;
import io.swagger.v3.oas.annotations.media.Schema;
import lombok.Getter;
import lombok.Setter;
import lombok.ToString;

import java.util.List;

/**
 * @author chengh
 * 菜单实体类
 */
@Getter
@Setter
@ToString(callSuper = true)
@TableName("sys_menu")
@Schema(name = "SysMenu对象", description = "菜单表")
public class SysMenu extends BaseEntity {

    @Schema(name = "id", description = "菜单ID")
    private Long id;

    @Schema(name = "menuName", description = "菜单名称")
    private String menuName;

    @Schema(name = "parentId", description = "父ID")
    private Long parentId;

    @Schema(name = "orderNum", description = "排序")
    private Integer orderNum;

    @Schema(name = "path", description = "地址")
    private String path;

    @Schema(name = "component", description = "组件")
    private String component;

    @Schema(name = "query", description = "查询条件")
    private String query;

    @Schema(name = "isFrame", description = "是否是isFrame")
    private String isFrame;

    @Schema(name = "isCache", description = "是否缓存")
    private String isCache;

    @Schema(name = "menuType", description = "菜单类型")
    private String menuType;

    @Schema(name = "visible", description = "菜单状态")
    private String visible;

    @Schema(name = "perms", description = "权限表示")
    private String perms;

    @Schema(name = "icon", description = "图标")
    private String icon;

    @Schema(name = "status", description = "状态")
    private String status;

    @Schema(name = "children", description = "子菜单集合")
    @TableField(exist = false)
    private List<SysMenu> children;
}
